#include <stdio.h>

int main() {
	int c = 0;
	while (++c, getchar() != EOF);
	printf("%d", c - 2);
	return 0;
}